<include file="Public:header" />
<div class="container main"> <include file="Public:left" />
  <div class="w790">
  <script>
  	function uploaded(path){
		$("#img_url").attr("src",'__PUBLIC__'+path);
		$("input[name='img_url']").val(path);
	}
	
	function del_img(){
		if(confirm('您确定要删除图片吗?')){
			var file=$("input[name='img_url']").val();
			$.post("{:U('delImgBypath')}",{'path':file},function(data){
				$("input[name='img_url']").val('');
				$("#img_url").attr('src','');
			});
		}else{
			return false;
		}
	}
	//删除图组图片
	function mdel_img(path){
		$('#img_list div img').each(function(index, element) {
			$.post("{:U('delImgBypath')}",{'path':path},function(data){
				if(data=='OK'){
					
					$('#img_list div').each(function(index, element) {
                        if($(this).attr('url')==path){
							$(this).remove();
						}
                    });
					
					$('#picmsg input').each(function(index, element) {
                        if($(this).val()==path){
							$(this).remove();
						}
                    });
				}
			});
		});
	}
  </script>
 <div class="h"><a href="{:U('index')}" class="btn btn-info"><i class="glyphicon glyphicon-circle-arrow-left"></i> 返回列表</a>
 
 </div>
    <form class="checkoutform form-horizontal" action="{:U('insert')}" method="post">
<div class="table_ container">
      <div class="form-group">
      <label class="col-sm-2 control-label">标题</label>
      <div class="col-sm-10">
         <input class="form-control" datatype="*"  name="title" type="text" >
      </div>
   </div>
   
       
        
        
        
       <div class="form-group">
      <label class="col-sm-2 control-label">图片</label>
      <div class="col-sm-10">
         <input name="img_url" type="hidden" value="{$info.img_url}" /><img onclick="showImgBox(this);" 
src="<notempty name="info['img_url']">{:getThumbPath($info['img_url'])}
<else/>__PUBLIC__/Admin/images/defaultimg.png</notempty>" id="img_url" height="40" />
      </div>
   </div>
      
      
<div class="form-group">
      <label class="col-sm-2 control-label">外部链接</label>
      <div class="col-sm-10">
         <input class="form-control" datatype="*"  name="link" type="text" >
      </div>
   </div>
   
       <div class="form-group">
      <label class="col-sm-2 control-label">备注</label>
      <div class="col-sm-10">
      <html:editor id="editor" name="remark" type="UEDIT" style="height:400px; width:100%;">{$info.remark}</html:editor>
      </div>
   </div>
   
      <div class="form-group">
      <label class="col-sm-2 control-label">排序</label>
      <div class="col-sm-10">
         <input class="form-control" datatype="*"  name="sort" type="text" value="{$info.sort}" >
      </div>
   </div>
   
       <div class="form-group">
      <label class="col-sm-2 control-label">显示</label>
      <div class="col-sm-10">
         <label class="checkbox-inline"> <input name="status" type="radio" id="is_nav_" value="1" checked="checked" />
          是</label>
          <label class="checkbox-inline">  <input name="status" type="radio" id="" value="0" />
          否</label>
      </div>
      </div>
      
        <div class="pages"><button type="submit" class="btn btn-success">提交</button></div>

    </form></div>
  </div>
  <div class="clear"></div>
</div>
</body></html>